// (c) Copyright Fernando Cerqueira.
// This source is subject to the Microsoft Public License (Ms-PL).
// Please see http://go.microsoft.com/fwlink/?LinkID=131993 for details.
// All other rights reserved.

using System.ComponentModel;
using Microsoft.Windows.Design;
using Microsoft.Windows.Design.Features;
using Microsoft.Windows.Design.Metadata;

namespace DevPhone.Controls.Design
{
    internal class CalendarControlMetadata : AttributeTableBuilder
    {
        public CalendarControlMetadata()
        {
            // Type attributes
            AddCustomAttributes(typeof(CalendarControl), new DescriptionAttribute("Represents a calendar with minimum and maximum value and mark color dates."));
            AddCustomAttributes(typeof(CalendarControl), new FeatureAttribute(typeof(CalendarControlInitializer)));
            AddCustomAttributes(typeof(CalendarControl), new ToolboxBrowsableAttribute(true));

            // Hide properties
            AddCustomAttributes(typeof(CalendarControl), "BorderThickness", new BrowsableAttribute(false));
            AddCustomAttributes(typeof(CalendarControl), "Background", new BrowsableAttribute(false));
            AddCustomAttributes(typeof(CalendarControl), "BorderBrush", new BrowsableAttribute(false));
            AddCustomAttributes(typeof(CalendarControl), "Foreground", new BrowsableAttribute(false));

            // Property attributes
            AddCustomAttributes(typeof(CalendarControl), "Culture", new CategoryAttribute(MetadataStore.CalendarProperties));
            AddCustomAttributes(typeof(CalendarControl), "Culture", new DescriptionAttribute("Gets or sets the culture of calendar."));

            AddCustomAttributes(typeof(CalendarControl), "CurrentDate", new CategoryAttribute(MetadataStore.CalendarProperties));
            AddCustomAttributes(typeof(CalendarControl), "CurrentDate", new DescriptionAttribute("Gets or sets the initial date."));

            AddCustomAttributes(typeof(CalendarControl), "CalendarBorderBrush", new CategoryAttribute(MetadataStore.BrushesProperties));
            AddCustomAttributes(typeof(CalendarControl), "CalendarBorderBrush", new DescriptionAttribute("Gets or sets the border color control."));

            AddCustomAttributes(typeof(CalendarControl), "CalendarBackground", new CategoryAttribute(MetadataStore.BrushesProperties));
            AddCustomAttributes(typeof(CalendarControl), "CalendarBackground", new DescriptionAttribute("Gets or sets the background control."));

            AddCustomAttributes(typeof(CalendarControl), "CalendarForeground", new CategoryAttribute(MetadataStore.BrushesProperties));
            AddCustomAttributes(typeof(CalendarControl), "CalendarForeground", new DescriptionAttribute("Gets or sets the foreground control."));
            
            AddCustomAttributes(typeof(CalendarControl), "CurrentDateBrush", new CategoryAttribute(MetadataStore.BrushesProperties));
            AddCustomAttributes(typeof(CalendarControl), "CurrentDateBrush", new DescriptionAttribute("Gets or sets the brush from initial date."));

            AddCustomAttributes(typeof(CalendarControl), "TodayBrush", new CategoryAttribute(MetadataStore.BrushesProperties));
            AddCustomAttributes(typeof(CalendarControl), "TodayBrush", new DescriptionAttribute("Gets or sets the brush from Today."));

            AddCustomAttributes(typeof(CalendarControl), "WeekBrush", new CategoryAttribute(MetadataStore.BrushesProperties));
            AddCustomAttributes(typeof(CalendarControl), "WeekBrush", new DescriptionAttribute("Gets or sets the brush from week name."));

            AddCustomAttributes(typeof(CalendarControl), "WeekBackground", new CategoryAttribute(MetadataStore.BrushesProperties));
            AddCustomAttributes(typeof(CalendarControl), "WeekBackground", new DescriptionAttribute("Gets or sets the background brush  from week name."));

            AddCustomAttributes(typeof(CalendarControl), "DisabledBrush", new CategoryAttribute(MetadataStore.BrushesProperties));
            AddCustomAttributes(typeof(CalendarControl), "DisabledBrush", new DescriptionAttribute("Gets or sets the disabled brush."));

            AddCustomAttributes(typeof(CalendarControl), "MarkPosition", new CategoryAttribute(MetadataStore.CalendarProperties));
            AddCustomAttributes(typeof(CalendarControl), "MarkPosition", new DescriptionAttribute("Gets or sets the mark position from day."));

            AddCustomAttributes(typeof(CalendarControl), "MarkWidth", new CategoryAttribute(MetadataStore.CalendarProperties));
            AddCustomAttributes(typeof(CalendarControl), "MarkWidth", new DescriptionAttribute("Gets or sets the mark width from day."));

            AddCustomAttributes(typeof(CalendarControl), "GestureDirection", new CategoryAttribute(MetadataStore.CalendarProperties));
            AddCustomAttributes(typeof(CalendarControl), "GestureDirection", new DescriptionAttribute("Gets or sets the gesture direction."));

            AddCustomAttributes(typeof(CalendarControl), "EnabledTapShowMonth", new CategoryAttribute(MetadataStore.CalendarProperties));
            AddCustomAttributes(typeof(CalendarControl), "EnabledTapShowMonth", new DescriptionAttribute("Gets or sets the enabled tap show months."));

            AddCustomAttributes(typeof(CalendarControl), "EnabledTapShowYear", new CategoryAttribute(MetadataStore.CalendarProperties));
            AddCustomAttributes(typeof(CalendarControl), "EnabledTapShowYear", new DescriptionAttribute("Gets or sets the enabled tap show years."));

            AddCustomAttributes(typeof(CalendarControl), "MaxDate", new CategoryAttribute(MetadataStore.CalendarProperties));
            AddCustomAttributes(typeof(CalendarControl), "MaxDate", new DescriptionAttribute("Gets or sets the maximum value of ranger date."));

            AddCustomAttributes(typeof(CalendarControl), "MinDate", new CategoryAttribute(MetadataStore.CalendarProperties));
            AddCustomAttributes(typeof(CalendarControl), "MinDate", new DescriptionAttribute("Gets or sets the minimum value of ranger date."));

            AddCustomAttributes(typeof(CalendarControl), "ShowLinkToday", new CategoryAttribute(MetadataStore.CalendarProperties));
            AddCustomAttributes(typeof(CalendarControl), "ShowLinkToday", new DescriptionAttribute("Gets or sets the show text today."));

            AddCustomAttributes(typeof(CalendarControl), "TodayHighlight", new CategoryAttribute(MetadataStore.CalendarProperties));
            AddCustomAttributes(typeof(CalendarControl), "TodayHighlight", new DescriptionAttribute("Gets or sets the highlight style from today."));

            AddCustomAttributes(typeof(CalendarControl), "LoopRangeMinMax", new CategoryAttribute(MetadataStore.CalendarProperties));
            AddCustomAttributes(typeof(CalendarControl), "LoopRangeMinMax", new DescriptionAttribute("Gets or sets the loop range between minimum and maximum."));

            AddCustomAttributes(typeof(CalendarControl), "TitleSelectMonth", new CategoryAttribute(MetadataStore.CalendarProperties));
            AddCustomAttributes(typeof(CalendarControl), "TitleSelectMonth", new DescriptionAttribute("Gets or sets the title text from months view."));

            AddCustomAttributes(typeof(CalendarControl), "TitleSelectYear", new CategoryAttribute(MetadataStore.CalendarProperties));
            AddCustomAttributes(typeof(CalendarControl), "TitleSelectYear", new DescriptionAttribute("Gets or sets the title text from years view."));

            AddCustomAttributes(typeof(CalendarControl), "TitleGoDay", new CategoryAttribute(MetadataStore.CalendarProperties));
            AddCustomAttributes(typeof(CalendarControl), "TitleGoDay", new DescriptionAttribute("Gets or sets the title text from go days view."));

            AddCustomAttributes(typeof(CalendarControl), "TitleGoMonth", new CategoryAttribute(MetadataStore.CalendarProperties));
            AddCustomAttributes(typeof(CalendarControl), "TitleGoMonth", new DescriptionAttribute("Gets or sets the title text from go months view."));

            AddCustomAttributes(typeof(CalendarControl), "TitleGoYear", new CategoryAttribute(MetadataStore.CalendarProperties));
            AddCustomAttributes(typeof(CalendarControl), "TitleGoYear", new DescriptionAttribute("Gets or sets the title text from go years view."));

            AddCustomAttributes(typeof(CalendarControl), "TitleToday", new CategoryAttribute(MetadataStore.CalendarProperties));
            AddCustomAttributes(typeof(CalendarControl), "TitleToday", new DescriptionAttribute("Gets or sets the title text from today link."));

            AddCustomAttributes(typeof(CalendarControl), "TitleNext", new CategoryAttribute(MetadataStore.CalendarProperties));
            AddCustomAttributes(typeof(CalendarControl), "TitleNext", new DescriptionAttribute("Gets or sets the title text from next months or years link."));

            AddCustomAttributes(typeof(CalendarControl), "TitlePrev", new CategoryAttribute(MetadataStore.CalendarProperties));
            AddCustomAttributes(typeof(CalendarControl), "TitlePrev", new DescriptionAttribute("Gets or sets the title text from previous months or years  link."));
        }

    }
}